home *** CD-ROM | disk | FTP | other *** search
- !Risk : Map information
- =======================
-
- Structure
- ---------
-
- A map file can be easily created by following these
- steps:
- a. Create an application directory (eg !map)
- b. Copy !Boot, !Run, !Sprites, Gamedata and
- Tempdata from another white map directory.
- c. Rename the sprite in !sprites to agree with the
- map name
- d. Create your map in a sprite called original and
- save as file Sprites this map can be of any
- size, unfortunately however I have not tried to
- create a map larger than the screen. The sprite
- must be created in mode 13.
- e. Using the information given later create a file
- Mapdata of filetype &436
- f. Test it
- g. If it works send me a copy, I'll then try to
- distribute it to registered users.
- h. Send it to the PD library you got your copy
- from.
- * Note if you're running a PD library you can delete
- section h if you like, or add some suitable
- comment.
-
- If you have any queries contact me at
-
- Steve Bosman
- 116 Flemming Avenue
- Leigh-on-sea
- Essex
- SS9 3AX
-
-
- Mapdata info
- ------------
-
- Appendix A contains a fragment of the program code
- required to load a map, whose location is given by
- the system variable <RiskMap$Dir>. Currently a map
- is limited to a maximum of fifty territories divided
- between a maximum of ten regions. Unfortunately
- because I am used to FORTRAN 77 arrays, position 0
- is hardly ever used. The variables used are :
-
- numberofterritories% should be between 6 and 50 inclusive
- numberofregions% should be between 1 and 10 inclusive
- territory$(50) names of territories
- territoryinfo%(0,50) # neighbouring territories
- territoryinfo%(20,50) neighbouring territories
- territorycol%(50) colour of territory on map (NOT !paint colour)
- territorytint%(50) tint of territory on map
- territoryflood%(50) number of sections making
- territory (max. 6) this
- allows for islands (see
- Greenland on !World map)
- territoryfloodx%(6,50) x position for flood
- territoryfloody%(6,50) y position for flood
- numberx%(50) x position for placing
- number of units
- numbery%(50) y position for placing
- number of units
- region%(10) number of last territory
- in region
- region$(10) name of region
- regionalbonus%(10) bonus for possessing an
- entire region
-
- Sprite info
- -----------
-
- A map sprite should be called 'original' and saved
- by itself in a file called Sprites in the Map
- directory. All territories on a newly created map
- should be in different colours. Also there should be
- definite borders between them, and also between them
- and the sea. The sea should be colour 61 tint 192,
- borders colour 63 tint 192, and neutral countries
- (eg Mexico/Canada on !USA) should be colour 42
- tint 192.
-
- Appendix A
- ----------
-
- X=OPENUP("<RiskMap$Dir>.MapData")
- INPUT#X,numberofterritories%
- FOR i%=1 TO numberofterritories%
- INPUT#X,territory$(i%),territoryinfo%(0,i%)
- FOR j%=1 TO territoryinfo%(0,i%)
- INPUT#X,territoryinfo%(j%,i%)
- NEXT
- INPUT#X,territorycol%(i%),territorytint%(i%)
- INPUT#X,territoryflood%(i%)
- FOR j%=1 TO territoryflood%(i%)
- INPUT#X,territoryfloodx%(j%,i%),territoryfloody%(j%,i%)
- NEXT
- INPUT#X,numberx%(i%),numbery%(i%)
- NEXT
- INPUT#X,numberofregions%
- FOR i%=1 TO numberofregions%
- INPUT#X,region%(i%),region$(i%),regionalbonus%(i%)
- NEXT
- CLOSE#X
- INPUT#X,territory$(i%),territoryinfo%(0,i%)
- FOR j%=1 TO territoryinfo%(0,i%)
- INPUT#X,territoryinfo%(j%,i%)
- NEXT
- INPUT#X,territorycol%(i%),territorytint%(i%)
- INPUT#X,territoryflood%(i%)
- FOR j%=1 TO territoryflood%(i%)
- INPUT#X,territoryfloodx%(j%,i%),territoryfloody%(j%,i%)
- NEXT
- INPUT#X,numberx%(i%),numbery%(i%)
- NEXT
- INPUT#X,numberofregions%
- FOR i%=1 TO numberofregions%
- INPUT#X,region%(i%),region$(i%),regionalbonus%(i%)
- NEXT
- CLOSE#X
-